package com.yc.java_basic2;

import java.util.Random;

public class Test5 {
	public static void main(String[] args) {
		//练习: 现在班级里面,有10个同学,考4门考试, 请给这些同学的考试成绩进行随机赋值
		int[][] grade = new int[10][4];
		Random r = new Random();
		
		for(int i = 0; i < grade.length; i++) {
			for(int j = 0; j < grade[i].length; j++) {
				grade[i][j] = r.nextInt(100);
			}
		}
		
		//输出
		for(int i = 0; i < grade.length; i++) {
			for(int j = 0; j < grade[i].length; j++) {
				System.out.print( grade[i][j] + " " );
			}
			System.out.println();
		}
	}
}
